import React from 'react'
import { Panel, Cell,CellHeader, CellBody } from 'react-weui'

export default class OrderTitle extends React.Component {
	handleGoBack() {
		history.go(-1);
	}
	componentDidMount(){
	}
	render() {
		return (
			<Panel style={{ position: 'fixed', top: 0, width: '100%', zIndex: 2 }}>
            	<Cell>
	                <CellHeader>
                        <i className="iconfont icon-back" style={{
                            fontSize: '1.4em',
                            color: 'gray'
                        }} onClick={this.handleGoBack.bind(this)}></i>
	            	</CellHeader>
               		<CellBody style={{ textAlign: 'center'}}>
                        {this.props.title}
                	</CellBody>
            	</Cell>
            </Panel>
		);
	}
}
